package com.order.common.entiry;

public enum ResultCode {
    SUCCESS(true,200,"请求成功"),
    SERVER_ERROR(false,9999,"系统异常"),
    FAIL(false,10001,"请求失败"),
    UNAUTHENTICATED(false,10002,"您还未登录"),
    UNAUTHORISE(false,10003,"权限不足"),
    NODATA(false,10004,"未查到数据"),
    UNMOBILE_OR_PASSWORD(false,20001,"用户账号或密码错误"),
    ACCOUNT_NOT_FOUND(false, 20002, "账号不存在"),
    ACCOUNT_ALREADY_EXISTS(false, 20003, "账号已存在"),
    PASSWORD_CANNOT_BE_EMPTY(false, 20004, "密码不能为空"),
    NO_ORDER_INFO(false, 20005, "无点餐信息"),
    ALREADY_BOOKED_OTHER_TABLE(false, 20006, "您已经预定了其他餐桌");

    private boolean success;

    private Integer code;

    private String msg;

    ResultCode(boolean success, Integer code, String msg) {
        this.success = success;
        this.code = code;
        this.msg = msg;
    }

    public boolean isSuccess() {
        return success;
    }

    public void setSuccess(boolean success) {
        this.success = success;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }

}
